@import './constants.less';
.ellipsis() {
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
}
.clearfix() {
  &:after {
    content: '';
    clear: both;
    display: block;
    height: 0;
    visibility: hidden;
    opacity: 0;
  }
}
.border() {
  content: '';
  position: absolute;
  left: 0;
  width: 100%;
  height: 0;
  z-index: 1;
  transform-origin: 0 0;
  transform: scaleY(0.5);
}
.borderTopBefore() {
  &:before {
    .border();
    border-top: 1px solid @colorBorder;
    top: 0;
  }
}
.borderTopAfter() {
  &:after {
    .border();
    border-top: 1px solid @colorBorder;
    top: 0;
  }
}
.borderBottomBefore() {
  &:before {
    .border();
    border-bottom: 1px solid @colorBorder;
    bottom: 0;
  }
}
.borderBottomAfter() {
  &:after {
    .border();
    border-bottom: 1px solid @colorBorder;
    bottom: 0;
  }
}
.arrow-right() {
  background: #fff url('../assets/arrow_right.png') scroll no-repeat right center;
  background-size: .17rem .28rem;
  padding-right: .26rem;
  line-height: .3rem;
  max-width: 100%;
  box-sizing: border-box;
}
.arrow-down() {
  background: #fff url('../assets/arrow_down.png') scroll no-repeat right center;
  background-size: .2rem .1rem;
  padding-right: .26rem;
  max-height: 100%;
  max-width: 100%;
  box-sizing: border-box;
}
.apple-switch() {
  position: relative;
  width: 1rem;
  height: .52rem;
  border-radius: .3rem;
  background-color: rgba(0, 184, 0, .8);
  border: 1px solid rgba(0, 0, 0, 0);
  transition: 150ms all linear 0ms;
  .apple-switch-inner {
    position: absolute;
    top: 0;
    right: 0;
    width: .52rem;
    height: .52rem;
    border-radius: 50%;
    background-color: #fff;
    box-shadow: 0 2px 4px 1px rgba(0, 0, 0, .4);
    transition: 150ms all linear 0ms;
  }
  &.off {
    background-color: rgba(255, 255, 255, .4);
    border: 1px solid rgba(0, 0, 0, .15);
    .apple-switch-inner {
      right: .5rem;
    }
  }
}
.tl {
  text-align: left;
}
